import request from '@/utils/request'

// 查询产品购买记录列表
export function listPurchaserecord(query) {
  return request({
    url: '/module/purchaserecord/list',
    method: 'get',
    params: query
  })
}

// 查询产品购买记录详细
export function getPurchaserecord(id) {
  return request({
    url: '/module/purchaserecord/' + id,
    method: 'get'
  })
}

// 新增产品购买记录
export function addPurchaserecord(data) {
  return request({
    url: '/module/purchaserecord',
    method: 'post',
    data: data
  })
}

// 修改产品购买记录
export function updatePurchaserecord(data) {
  return request({
    url: '/module/purchaserecord',
    method: 'put',
    data: data
  })
}

// 删除产品购买记录
export function delPurchaserecord(id) {
  return request({
    url: '/module/purchaserecord/' + id,
    method: 'delete'
  })
}

// 导出产品购买记录
export function exportPurchaserecord(query) {
  return request({
    url: '/module/purchaserecord/export',
    method: 'get',
    params: query
  })
}